{if isset($error_msg)}
{$error_msg}
{/if}
<script type="text/javascript" src="{$DESIGN_PATH}access/script.js"></script>
<form action="{$REQUEST_URI}" method="post" accept-charset="UTF-8">
	<fieldset>
		<dl>
			<dt><label for="name">{lang values="common|name"}</label></dt>
			<dd><input type="text" name="form[name]" id="name" value="{$form.name}" maxlength="120" /></dd>
		</dl>
		<table class="acp-table">
			<caption>
				{lang values="access|access_level_selection_tip"}
			</caption>
			<thead>
				<tr class="sub-table-header">
					<th>{lang values="common|modules"}</th>
					<th><a href="javascript:mark_permissions('read','toggle');">{lang values="access|can_read"}</a></th>
					<th><a href="javascript:mark_permissions('create','toggle');">{lang values="access|can_create"}</a></th>
					<th><a href="javascript:mark_permissions('edit','toggle');">{lang values="access|can_edit"}</a></th>
					<th><a href="javascript:mark_permissions('delete','toggle');">{lang values="access|can_delete"}</a></th>
				</tr>
			</thead>
			<tbody>
{foreach from=$mod_list item=mod}
				<tr>
					<td>{$mod.name}</td>
					<td><input type="checkbox" name="form[modules][{$mod.dir}][read]" value="1" class="access-read checkbox"{$mod.read_checked} /></td>
					<td><input type="checkbox" name="form[modules][{$mod.dir}][create]" value="1" class="access-create checkbox"{$mod.create_checked} /></td>
					<td><input type="checkbox" name="form[modules][{$mod.dir}][edit]" value="1" class="access-edit checkbox"{$mod.edit_checked} /></td>
					<td><input type="checkbox" name="form[modules][{$mod.dir}][delete]" value="1" class="access-delete checkbox"{$mod.delete_checked} /></td>
				</tr>
{/foreach}
			</tbody>
		</table>
	</fieldset>
	<div class="form-bottom">
		<input type="submit" name="submit" value="{lang values="common|submit"}" class="form" />
	</div>
</form>